local app = require "app"
local gamelib = require "club.threecard.gamelib"

local game = gamelib.game.new({
    package = "club.threecard.texas",
    modules = {
        seat = "club.threecard.texas.seat"
    },
    libs = {
        pokerlib = "club.threecard.pokerlib",
        casinolib = "club.threecard.casinolib",
    },
    on_start = function(self)
        local entrances = require "club.threecard.texas.gamescene_entrance.entrances"
        gamelib.game_scene.overried_entrance(entrances)
        self.kbe.register("TexaspokerPlayer")
        self.kbe.register("TexaspokerRoom")
        self.ui.init_routes()
    end,
    on_started = function(self)
        self.audio.post("texas:bgm")
        if self.reconnection.fast_resume() then
            return
        end
        self.router.go('/club.threecard.texas/lobby')
    end
})

return game